object frmeSale: TfrmeSale
  Left = 0
  Top = 0
  Width = 451
  Height = 304
  Align = alClient
  TabOrder = 0
  object ToolBar1: TToolBar
    Left = 0
    Top = 0
    Width = 451
    Height = 36
    AutoSize = True
    ButtonHeight = 36
    ButtonWidth = 138
    Images = DM.ImageListMain
    ShowCaptions = True
    TabOrder = 1
    object ToolButton1: TToolButton
      Left = 0
      Top = 0
      Action = actAdd
      ParentShowHint = False
      ShowHint = True
    end
    object ToolButton2: TToolButton
      Left = 138
      Top = 0
      Action = actEdit
      ParentShowHint = False
      ShowHint = True
    end
    object ToolButton3: TToolButton
      Left = 276
      Top = 0
      Action = actDel
      ParentShowHint = False
      ShowHint = True
    end
  end
  object cxgWares: TcxGrid
    Left = 0
    Top = 74
    Width = 451
    Height = 230
    Align = alClient
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clWindowText
    Font.Height = -11
    Font.Name = 'MS Sans Serif'
    Font.Style = []
    ParentFont = False
    PopupMenu = pmMenu
    TabOrder = 2
    LookAndFeel.Kind = lfOffice11
    LookAndFeel.NativeStyle = False
    object cxgWaresDBTableView1: TcxGridDBTableView
      OnDblClick = cxgWaresDBTableView1DblClick
      NavigatorButtons.ConfirmDelete = False
      DataController.DataSource = dsSale
      DataController.Summary.DefaultGroupSummaryItems = <>
      DataController.Summary.FooterSummaryItems = <
        item
          FieldName = 'address'
        end>
      DataController.Summary.SummaryGroups = <>
      OptionsBehavior.IncSearch = True
      OptionsCustomize.ColumnsQuickCustomization = True
      OptionsData.CancelOnExit = False
      OptionsData.Deleting = False
      OptionsData.DeletingConfirmation = False
      OptionsData.Editing = False
      OptionsData.Inserting = False
      OptionsView.ColumnAutoWidth = True
      OptionsView.Indicator = True
      Styles.IncSearch = DM.sIncSearch
      Styles.Selection = DM.sSelection
      Styles.GroupByBox = DM.sGroupBox
      Styles.Header = DM.sHeader
      object cxgWaresDBTableView1id_sale: TcxGridDBColumn
        DataBinding.FieldName = 'id_sale'
        Visible = False
        VisibleForCustomization = False
      end
      object cxgWaresDBTableView1waretitle: TcxGridDBColumn
        Caption = #1053#1072#1079#1074#1072#1085#1080#1077
        DataBinding.FieldName = 'waretitle'
        Options.Editing = False
        Width = 206
      end
      object cxgWaresDBTableView1date_sale: TcxGridDBColumn
        Caption = #1044#1072#1090#1072' '#1087#1088#1086#1076#1072#1078#1080
        DataBinding.FieldName = 'date_sale'
        Options.Editing = False
        Width = 111
      end
      object cxgWaresDBTableView1count_wares: TcxGridDBColumn
        Caption = #1050#1086#1083#1080#1095#1077#1089#1090#1074#1086
        DataBinding.FieldName = 'count_wares'
        Options.Editing = False
        Width = 100
      end
      object cxgWaresDBTableView1wares_price: TcxGridDBColumn
        Caption = #1062#1077#1085#1072', '#1088
        DataBinding.FieldName = 'wares_price'
        Options.Editing = False
        Width = 70
      end
      object cxgWaresDBTableView1payment: TcxGridDBColumn
        Caption = #1054#1087#1083#1072#1090#1072
        DataBinding.FieldName = 'payment'
        Options.Editing = False
        Width = 64
      end
      object cxgWaresDBTableView1DBClient: TcxGridDBColumn
        Caption = #1060#1048#1054' '#1082#1083#1080#1077#1085#1090#1072
        DataBinding.FieldName = 'client_fio'
        Width = 200
      end
      object cxgWaresDBTableView1DBoperator_fio: TcxGridDBColumn
        Caption = #1054#1087#1083#1072#1090#1091' '#1087#1088#1080#1085#1103#1083'('#1072')'
        DataBinding.FieldName = 'operator_fio'
        HeaderAlignmentHorz = taCenter
        Options.Editing = False
        Options.Filtering = False
        Width = 94
      end
    end
    object cxgWares1Level1: TcxGridLevel
      GridView = cxgWaresDBTableView1
    end
  end
  object Panel1: TPanel
    Left = 0
    Top = 36
    Width = 451
    Height = 38
    Align = alTop
    BevelOuter = bvNone
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clWindowText
    Font.Height = -11
    Font.Name = 'MS Sans Serif'
    Font.Style = []
    ParentFont = False
    TabOrder = 0
    object cxLabel1: TcxLabel
      Left = 8
      Top = 10
      Caption = #1055#1086#1082#1072#1079#1072#1090#1100' '#1087#1088#1086#1076#1072#1078#1080' '#1089#1086#1079#1076#1072#1085#1085#1099#1077' '#1089' '
    end
    object deDateBegin: TcxDateEdit
      Left = 191
      Top = 8
      Properties.InputKind = ikMask
      Properties.Kind = ckDateTime
      Properties.ReadOnly = False
      TabOrder = 0
      Width = 130
    end
    object deDateEnd: TcxDateEdit
      Left = 339
      Top = 8
      BiDiMode = bdLeftToRight
      ParentBiDiMode = False
      Properties.InputKind = ikMask
      Properties.Kind = ckDateTime
      TabOrder = 1
      Width = 130
    end
    object cxLabel2: TcxLabel
      Left = 322
      Top = 10
      Caption = #1087#1086
    end
    object btnRun: TButton
      Left = 478
      Top = 6
      Width = 75
      Height = 25
      Action = actLoad
      Default = True
      ParentShowHint = False
      ShowHint = True
      TabOrder = 2
    end
  end
  object qSale: TADOQuery
    Connection = DM.Conection
    CursorType = ctStatic
    LockType = ltReadOnly
    Parameters = <
      item
        Name = 'datebegin'
        Size = -1
        Value = Null
      end
      item
        Name = 'dateend'
        Size = -1
        Value = Null
      end>
    SQL.Strings = (
      'SELECT'
      '    id_sale,'
      '    date_sale,'
      
        '    (SELECT Trim(wares.title) FROM wares WHERE wares.id_wares= s' +
        'ale.id_wares) as waretitle,'
      
        '    (SELECT Trim(lastname) & '#39' '#39' & Left(name, 1) & '#39'. '#39' & Left(p' +
        'atronimyc,1) FROM workers WHERE workers.id_worker= sale.id_opera' +
        'tor_pay) as operator_fio,'
      '    count_wares,'
      '    wares_price , payment, id_wr,'
      
        '    (SELECT Trim(lastname) & '#39' '#39' & Left(name, 1) & '#39'. '#39' & Left(p' +
        'atronimyc,1) FROM client WHERE client.id_client=sale.id_client) ' +
        'as client_fio'
      'FROM  sale'
      'WHERE'
      '    date_sale BETWEEN :datebegin AND :dateend  '
      'ORDER BY'
      '  date_sale'
      ''
      '')
    Left = 496
    Top = 80
  end
  object ActionList: TActionList
    Images = DM.ImageListMain
    Left = 432
    Top = 80
    object actAdd: TAction
      Caption = #1055#1088#1086#1076#1072#1090#1100' '#1090#1086#1074#1072#1088
      Hint = #1055#1088#1086#1076#1072#1090#1100' '#1090#1086#1074#1072#1088
      ImageIndex = 16
      ShortCut = 45
      OnExecute = actAddExecute
      OnUpdate = actAddUpdate
    end
    object actDel: TAction
      Caption = #1059#1076#1072#1083#1080#1090#1100' '#1087#1088#1086#1076#1072#1078#1091' '#1090#1086#1074#1072#1088#1072
      Hint = #1059#1076#1072#1083#1080#1090#1100' '#1087#1088#1086#1076#1072#1078#1091' '#1090#1086#1074#1072#1088#1072
      ImageIndex = 1
      ShortCut = 46
      OnExecute = actDelExecute
      OnUpdate = actUpdate
    end
    object actEdit: TAction
      Caption = #1054#1087#1083#1072#1090#1080#1090#1100' '#1090#1086#1074#1072#1088
      Hint = #1054#1087#1083#1072#1090#1080#1090#1100' '#1090#1086#1074#1072#1088
      ImageIndex = 6
      ShortCut = 16436
      OnExecute = actEditExecute
      OnUpdate = actEditUpdate
    end
    object actLoad: TAction
      Caption = #1047#1072#1075#1088#1091#1079#1080#1090#1100
      Hint = #1047#1072#1075#1088#1091#1079#1080#1090#1100' '#1089#1087#1080#1089#1086#1082' '#1087#1088#1086#1076#1072#1078
      OnExecute = actLoadExecute
    end
  end
  object dsSale: TDataSource
    DataSet = qSale
    Left = 464
    Top = 80
  end
  object acTemp: TADOCommand
    Connection = DM.Conection
    Parameters = <>
    Left = 392
    Top = 80
  end
  object pmMenu: TPopupMenu
    Images = DM.ImageListMain
    Left = 240
    Top = 128
    object N2: TMenuItem
      Action = actEdit
    end
  end
  object cxPropertiesStore1: TcxPropertiesStore
    Components = <
      item
        Component = deDateBegin
        Properties.Strings = (
          'Date')
      end
      item
        Component = deDateEnd
        Properties.Strings = (
          'Date')
      end>
    StorageName = 'cxPropertiesStore1'
    StorageType = stRegistry
    Left = 104
    Top = 160
  end
end
